﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using libtcod;

namespace CSRoguelike
{
    class Actor
    {
        public int X, Y;
        private char Icon;
        private TCODColor color;

        public Actor(int x, int y, char icon, TCODColor color)
        {
            this.X = x;
            this.Y = y;
            this.Icon = icon;
            this.color = color;
        }

        public void Move(int dx, int dy)
        {
            this.X += dx;
            this.Y += dy;
        }

        public void Draw(TCODConsole con)
        {
            con.setForegroundColor(this.color);
            con.putChar(X, Y, Icon);
        }

        public void Clear(TCODConsole con)
        {
            con.putChar(X, Y, ' ');
        }

        public void SetLocation(int x, int y)
        {
            this.X = x;
            this.Y = y;
        }
    }
}
